package com.molichuxing.gateway.api.services;

import com.molichuxing.framework.result.ResponseResult;
import com.molichuxing.gateway.bff.statistics.entity.response.*;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.List;
import java.util.Map;

/**
 * @Author: renzhengyu
 * @Description: 统计
 * @Date: Created in 16:05 2019/10/14
 * @Modified By:
 **/
public interface StatisticsApiService {
    /**
     * 首页订单统计
     *
     * @return
     */
    ResponseResult<HomeOrderStatisticsVo> getHomeOrderStatisticsVo();

    /**
     * 资源统计
     *
     * @return
     */
    ResponseResult<ResourceStatisticsVo> getResourceStatisticsVo();


    /**
     * 订单统计
     *
     * @return
     */
    ResponseResult<PreviousOrderStatisticsVo> getOrderStatisticsVo(Map<String, Object> map);

    /**
     * 违章统计
     *
     * @return
     */
    ResponseResult<ViolationCountVo> getViolationStatisticsVo();

    /**
     * 待处理事务统计
     *
     * @return
     */
    ResponseResult<PendStatisticsVo> getPendStatisticsVo();

    /**
     * 风险统计
     *
     * @return
     */
    ResponseResult<RiskStatisticsVo> getRiskStatisticsVo();

    /**
     * 订单地域分布统计
     *
     * @return
     */
    public ResponseResult<List<DistributionStatisticsVo>> getOrderRegionalDistribution();

    /**
     * 车型销售统计
     *
     * @return
     */
    public ResponseResult<List<SalesStatisticsVo>> getOrderVehicleSales();

    /**
     * 商品销售统计 (专属、订阅)
     *
     * @param orderType
     * @return
     */
    public ResponseResult<List<SalesStatisticsVo>> getOrderGoodsSales(Integer orderType);

    /**
     * 订单用户画像 (性别分布、年龄分布)
     *
     * @return
     */
    public ResponseResult<OrderUserPortraitVo> getOrderUserPortrait();

    /**
     * 资产统计
     *
     * @return
     */
    public ResponseResult<AssetCountVo> getAssetCount();

    /**
     * 导出
     *
     * @param request
     * @param response
     * @return
     */
    public void getAssetCountDownload(HttpServletRequest request, HttpServletResponse response);
}
